<?php
function Test() {
	static $a = 0;
	echo $a;
	$a ++;
}
Test ();
Test ();
Test ();
Test ();
?> 
<?php
function Test2() {
	static $count = 0;
	
	$count ++;
	echo $count;
	if ($count < 10) {
		Test2 ();
	}
	$count --;
}
Test2 ();
?> 